package com.itheima.features.process;

import java.io.IOException;

public class ProcessBuilderDemo {

    public static void main(String[] args) throws IOException {

        ProcessBuilder processBuilder = new ProcessBuilder();
        processBuilder.command("notepad.exe");
        Process process = processBuilder.start();
        System.out.println("pid---->" + process.pid());

        ProcessHandle.Info info = process.info();
        System.out.println(info.arguments());
        System.out.println(info.startInstant());
        System.out.println(info.user());
        System.out.println(info.command());

    }
}
